package com.wenhao.newcode.iqiyi;

import java.util.Scanner;

/**
 * @author Wenhao Tong
 * @date 2021/7/15 下午11:10
 */
public class Main2020_1 {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int x = scanner.nextInt();
        int y = scanner.nextInt();
        int z = scanner.nextInt();
        int k = scanner.nextInt();
        int[] num = new int[]{1,1,1};
        for (int i = 0;i < k;i++) {
            if (x > 1) {
                x--;
                k--;
                num[1] *= 2;
                num[2] *=2;
            }
            if (y > 1) {
                y--;
                k--;
                num[0] *= 2;
                num[2] *= 2;
            }
            if (z > 1) {
                z--;
                k--;
                num[0] *= 2;
                num[2] *= 2;
            }
        }
        System.out.println(num[0] * num[1] * num[2]);
    }
}
